package com.sky.service.user;

import com.sky.pojo.AddressBook;

import java.util.List;

/**
 * @Description AddressBookService
 * @Author lyh
 * @Date 2024-10-08
 */
public interface AddressBookService {
    /**
     * 查询当前用户所有地址
     * @return
     */
    List<AddressBook> list();

    /**
     * 新增地址
     * @param addressBook
     */
    void addAddress(AddressBook addressBook);

    /**
     * 根据id查询地址
     * @param id
     * @return
     */
    AddressBook getById(Long id);

    void update(AddressBook addressBook);

    void setDefault(AddressBook addressBook);

    void deleteById(Long id);

    List<AddressBook> getDefault();
}
